<?php
$this->widget('webroot.admin.protected.extensions.fancybox.EFancyBox', array('target' => '.fan', 'config' => array('width' => 720, 'height' => 330,'type'=>'iframe','hideOnOverlayClick'=>false)));
?>
<script>
function loginCheck(){
	var username = document.getElementById('username');
	var password = document.getElementById('password');
	var verifycode = document.getElementById('verifycode');
	if(username.value==''){
		alert("帳號不能為空");
		username.focus();
		return false;
	}
	if(password.value==''){
		alert("密碼不能為空");
		password.focus();
		return false;
	}
	if(verifycode.value==''){
		alert("驗證碼不能為空");
		verifycode.focus();
		return false;
	}
	document.loginForm.submit();
}
<?php
if($msg){
?>
alert('<?=$msg?>');
<?php
}
?>
</script>
<style>
#loginTable tr td {
	border-bottom: 0px;
	padding: 0;
}
</style>
<?php $this->beginWidget('application.widget.site.bannerWidget'); ?>
<?php $this->endWidget(); ?>
<div id="contener" _height="auto">
	<div class="left_menu">
		<?php $this->beginWidget('application.widget.site.leftWidget'); ?>
		<?php $this->endWidget(); ?>
		<?php $this->beginWidget('application.widget.site.faceWidget'); ?>
		<?php $this->endWidget(); ?>
	</div>
	<div class="main">
		<?php $this->beginWidget('application.widget.site.newWidget'); ?>
		<?php $this->endWidget(); ?>
		<div class="right_mainBox">
			<div class="right_mainBox_top"></div>
			<div class="mainMenu"> <img src="images/title23.gif" alt="會員登入" title="會員登入" width="726" height="23" /></div>
			<div class="mainContentBox">
				<h1>Jowin!揪贏網 揪夥厚禮Song! 愛揪才會贏! </h1>
				<ol style=" list-style: decimal;">
					<li> 不定期舉辦抽獎活動! 各項大獎大方送 ！ </li>
					<li>只要完成註冊及驗證程序，馬上贈送10點鴻運點數!</li>
				</ol>
				<div class="box">
					<div id="box_contant">
						<form action="" method="post" name="loginForm" id="loginForm">
							<div class="contentright" id="box_contentright">
								<table id="loginTable" width="378" height="134" border="0" cellpadding="0" cellspacing="0">
									<tr>
										<td width="94">請輸入帳號：</td>
										<td width="284">
											<input type="text" name="username" id="username" value="<?=$model->username?>" />
										</td>
									</tr>
									<tr>
										<td>請輸入密碼：</td>
										<td>
											<input type="password" name="password" id="password" value="<?=$model->password?>" />
										</td>
									</tr>
									<tr>
										<td>驗證碼:</td>
										<td>
											<?php $this->widget ( 'CCaptcha', array ('showRefreshButton' => true, 'clickableImage' => true, 'buttonType' => 'link', 'buttonLabel' => '更換', 'imageOptions' => array ('alt' => '點擊換圖', 'title' => '點擊換圖', 'style' => 'vertical-align:middle;cursor:pointer;height:30px;width:60px;margin-left:5px;' ) ) );?>
											<input name="verifycode" type="text" id="verifycode" size="8" maxlength="4" />
										</td>
									</tr>
								</table>
								<div id="apDiv2">
									<div class="buttonA" style="float:left; margin-right:10px"><a href="###" onclick="loginCheck();" title="會員登入" target="_self">登入</a></div>
									<a href="<?=Yii::app()->createUrl('site/forgotPwd')?>" class="fan" title="忘記帳號/密碼？">忘記帳號/密碼？</a> </div>
							</div>
						</form>
					</div>
				</div>
			</div>
			<div class="right_mainBox_bottom"></div>
		</div>
	</div>
</div>
